﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using UMLTouch.Core.UI;
using System.Windows;

namespace UMLTouch.Core.Models
{
    public class AnchorPlug : DiagramAnchor
    {
        AnchorSlot _slot;

        public AnchorSlot Slot
        {
            get { return _slot; }
            set {
                if(_slot != null)
                _slot.Plugs.Remove(this);

                _slot = value;
                if (_slot != null)
                {
                    _slot.Plugs.Add(this);
                    this.MoveTo(_slot.Position);
                }
            }
        }
       

        public AnchorPlug(IDiagramItem parent,Point position)
            :base(parent,position)
        {
          
        }

       
        
    }
}
